# -*- coding: utf-8 -*-
from  flask import Flask,render_template
import os
app=Flask(__name__)

#获取文件加下的图片
all_folds = os.listdir('./static/images')


#获取文件夹下面图片的名字信息
all_image = [x for x in all_folds if '.' in x]
image_list=[]
for i in range(len(all_image)):
        base_image="../static/images/{}".format(all_image[i])
        image_list.append(base_image)


@app.route('/')
def reg():
    return render_template('zpq.html',data=image_list)

@app.route('/mo')
def index():
    return render_template('index1.html')

if __name__=='__main__':
    app.run()
